﻿using System;
using Microsoft.SharePoint;
using Microsoft.SharePoint.WebControls;
using Microsoft.SharePoint.Administration;
using Microsoft.SharePoint.Utilities;
using System.Web.UI.WebControls;
using System.Web.UI;

namespace CodeCounsel.SharePoint.NavigationService
{
    public partial class TestPage : Page
    {
        protected Label statusLabel;

        protected override void OnLoad(EventArgs e)
        {
            if (IsPostBack == false)
            {
                NavigationApplicationProxy proxy = NavigationApplicationProxy.GetProxy(SPServiceContext.Current);
                statusLabel.Text = proxy != null ? proxy.GetNavigationInformation() : "Not Connected";
            }
            base.OnLoad(e);
        }
    }
}
